import React, { Component } from 'react'
import { Form, Input, Button } from 'antd'

const spanConfig = { labelCol: { span: 4 }, wrapperCol: { span: 10 } }
const { labelCol, wrapperCol } = spanConfig
export default class StudentFrom extends Component {

    onFinish = () => {
        console.log('ti');
    }
    render() {
        return (

            <Form
                {...spanConfig}
                onFinish={this.onFinish} >
                {/* Form组件 仅提供样式和事件 */}
                <Form.Item
                    label="账号"
                    name="username">
                    <Input />
                </Form.Item>
                <Form.Item wrapperCol={{
                    offset: 4
                }}>
                    <Button htmlType='submit'> 提交</Button>
                </Form.Item>
            </Form>
        )
    }
}
